<template>
    <div>
        <h1>支付结果</h1>
        <p v-if="payResult">支付成功！</p>
        <p v-else>"支付失败！请重试"</p>
    </div>
</template>
<script setup name="PayResult">
import axiosInstance from '@/utils/axiosUtils';
import { ref } from 'vue';
import { useRoute } from 'vue-router';
const route=useRoute();
const payResult=ref(false);
if(route.query.payResult==='true'){
    payResult.value=true;
}
//    const response=await axiosInstance.get('/api/alipay/return')
//    const urlParams=new URLSearchParams(window.location.search);
//    const tradeStatus=urlParams.get('trade_status');
//    this.payResult=response.data.payResultt=tradeStatus=='TRADE_SUCCESS';

</script>